Check offline updates for incompatibility#2361
Conversation
310c562 to
29cedf7
Compare
|
I considered adding playwright testing, but then I'd have to mock the year version which feels like doing too much. |
photon-targeting/src/main/java/org/photonvision/common/hardware/Platform.java
Show resolved
Hide resolved
acb6bc6 to
0ee2f0c
Compare
c735e1b to
77e51a7
Compare
77e51a7 to
4b2e3d7
Compare
|
Tested rejection on incorrect arch, rejection on incorrect filename pattern. Image version matching and dev version checks also work, prompting for confirmation. |
|
What does "version that is not your image" mean? I think we should also include steps for what the user ought to do (ie, update their base image, use the correct jar, etc) as well on that page |
Based on OsMetadata, the image version that we write to disk when we run our scripts in photon-image-modifier. |
|
Ok. The MR description says diffferent year than the current image -- if that's the case, let's make the modal say that explicitly |
e4d1312 to
1be7bc6
Compare
1be7bc6 to
c6df533
Compare
c6df533 to
1784ddd
Compare


Description
We've been experiencing a variety of issues where people are performing an offline update with an incompatible jar, which leads to bricking their device. This PR aims to help users avoid this issue. We will deny offline updates built for a different platform, as well asking for confirmation when updating with a dev jar, or a jar built for a different year than the current image.
Note that this functionality is entirely dependent on the filename of the jar, and does not use any metadata.
This PR additionally increases the snackbar message timeout from 2 to 5 seconds, as we've found 2 seconds isn't sufficient to fully read the message.
closes #2357
Meta
Merge checklist: